import * as types from '../mutation-types'
import _set from 'lodash/set'

const state = {
  dataList: false
}
const mutations = {
  [types.USER_MANAGE_UPDATE_STATE]: (state, payload) => {
    _set(state, payload.path, payload.value)
  }
}
const actions = {
  [types.USER_MANAGE_GET_LIST]: ({ commit }, params) => {
    console.log('======params>>>>====', params)
    commit(types.USER_MANAGE_UPDATE_STATE, { path: 'dataList', value: !state.dataList })
  }
}
export default {
  state,
  actions,
  mutations
}
